﻿import { mergeMap as _observableMergeMap, catchError as _observableCatch } from 'rxjs/operators';
import { Observable, from as _observableFrom, throwError as _observableThrow, of as _observableOf } from 'rxjs';
import { Injectable } from '@angular/core';
import { Client } from '../../app.client';
import { LoginVm, LoginResponseVm } from './login.define';

@Injectable({
    providedIn: 'root'
})
export class UserClient extends Client {
    login(loginVm: LoginVm): Observable<LoginResponseVm> {
      const url_ = this.getUrl('/user/login');
      const options_: any = this.getOptions(loginVm);
      return this.request<LoginResponseVm>('post', url_, options_, LoginResponseVm);
    }
}
